package HomeTask1;

import java.io.*;

public class Main {

	public static void main(String[] args) throws IOException {

		BufferedReader stdin = new BufferedReader(new InputStreamReader(System.in));
		System.out.println("Input string");
		String string = stdin.readLine();
		StringBuffer str = new StringBuffer();

		str.append(string);

		str.reverse();
		System.out.println("Output string");
		System.out.println(str);

	}

}
